#include "form.h"
#include"mainwindow.h"
#include "ui_form.h"
#include <QPainter>
Form::Form(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::Form)
{
    ui->setupUi(this);
}

Form::~Form()
{
    delete ui;
}

void Form::on_pushButton_clicked()
{
    this->close();
    f=new MainWindow;
    f->show();
}
void Form::paintEvent(QPaintEvent* event){
    QPainter painter(this);
    painter.drawPixmap(0,0,800,600,QPixmap("://z/1649496742(1).png"));
    painter.setRenderHint(QPainter::Antialiasing); //设置抗锯齿
}
